package org.example.controller;

import org.apache.ibatis.annotations.Param;
import org.example.entity.Company;
import org.example.service.CompanyService;
import org.example.util.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @ClassName CompanyController
 * @Description TODO
 * @Author qiuye
 * @Date 2025年08月14日 14:40
 * @Version 1.0
 */
@RestController
@RequestMapping("company")
public class CompanyController {
    @Autowired
    private CompanyService companyService;
    @GetMapping("{id}")
    public R getCompany(@PathVariable int id){
        Company company = companyService.getCompany(id);
        return R.ok(company);
    }
}
